Skip to content

fix(pdf-codec): leave the module-level glyph tables out of mutation scope - #1843

Merged
Mearman merged 1 commit into
mainfrom
fix/pdf-codec-static-table-mutants
Nov 26, 2026
Merged

Mearman merged 1 commit into
mainfrom
fix/pdf-codec-static-table-mutants

Conversation

@Mearman

@Mearman Mearman commented Nov 26, 2026

Copy link
Copy Markdown
Member

pdf-codec scored 78.94 in scheduled run 45604657786 (79.20 in run 45395394611 the day before) against a break threshold of 85 measured at #1623 in September. That run was complete (all eight slices finished, 17,855 valid mutants), so the drop is real, and it comes almost entirely from four data-table modules added in November: dingbat-characters.ts (771 survivors), verified-glyph-tables-advent.ts (389), wingdings-characters.ts (257) and verified-glyph-tables-truetype.ts (232). Every one of those 1,649 survivors is a static mutant with test coverage, which is Stryker's hybrid case: under ignoreStatic it is switched on in a beforeAll() hook after the test file's imports have already evaluated the table, so no assertion can ever see it (document-schema.js's stryker.config.ts documents the mechanism).

These are not test gaps. With one entry each blanked by hand in dingbat-characters.ts and wingdings-characters.ts, wingdings-characters.test.ts fails. The verified glyph tables are keyed by font-program digests the suite doesn't carry; verified-glyph-tables.test.ts covers how a table is selected and read.

This change takes the four files out of pdf-codec's mutate globs, the same form as web's !src/**/*.css.ts. The threshold is unchanged. Rescoring run 45604657786's own reports without those files gives 86.97 (14,095 detected of 16,206 valid, timeout share 2.75%), which clears 85.

core-font-glyph-orders.ts and glyph-names.ts also have static survivors (68 and 57) but mix them with killed runtime mutants, so they stay in scope for tests.

Refs #1791

…cope

The Wingdings, dingbat and verified glyph table modules are nothing but
module-level data, so every mutant in them is a hybrid static mutant:
under ignoreStatic it is activated after the test file's imports have
already evaluated the table, and survives whatever the tests assert.
They held 1649 of pdf-codec's surviving mutants and pulled its score
below the break threshold it was measured at before they existed.

A hand edit to a Wingdings or dingbat entry fails
wingdings-characters.test.ts, so those survivors were never a gap in
the tests. The files are excluded through the mutate globs, the same
form as web's vanilla-extract exclusion.

Refs #1791
@claude

claude Bot commented Nov 26, 2026

Copy link
Copy Markdown

⚠️ PR Steward hasn't started: your organization has no extra usage available to pay for it, so it isn't working on this pull request.

If your organization's extra usage balance is empty or was never set up, an Owner of your Claude organization can add extra usage credits at claude.ai/admin-settings/usage. If your organization's monthly spend limit for extra usage is $0 or was reached, an Owner can raise it on the same page. If neither applies, contact Anthropic support.

Once that's fixed, PR Steward starts at the next push to this pull request.

Settings

@Mearman
Mearman added this pull request to the merge queue Nov 26, 2026
Merged via the queue into main with commit 307729a Nov 26, 2026
36 checks passed
@Mearman
Mearman deleted the fix/pdf-codec-static-table-mutants branch November 26, 2026 09:21
@github-actions

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 5.10.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant